{% extends "afcp/admin/admin.html" %}
{% comment %}
<!--
  Copyright (C) 2008 ZHENG Zhong <heavyzheng nospam-at gmail D0T com>
  - http://heavyz.blogspot.com/
  - http://buggarden.blogspot.com/

  The about page of the AFCP webapp, French version (fr).
  
  Created on 2008-11-20.
  $Id: set_current_activity.html 26 2009-08-04 22:06:00Z guolin.mobi $
-->
{% endcomment %}
{% load i18n %}

{% block header %}
{% endblock %}{# header #}

{#------------------------------------------------------------------------------------------------#}
{% block html_title %}
<title>Admin console</title>


<link rel="stylesheet" type="text/css" media="screen,print" href="{{ static_ }}/afcp/stylesheets/sections.css"/>

<script type="text/javascript">//<![CDATA[

function closeMessage() {
    $(".message").hide("slow");
}

function showInscription() {
    $("#edit_activity"  ).hide();
    $("#activity"       ).show("slow");
}

function showEditForm() {
    $("#activity"       ).hide();
    $("#edit_activity"  ).show("slow");
}

function submitEditForm() {
   // $("#edit_inscription :button").attr("disabled", "disabled");
    $("#edit_activity").submit();
}
//]]></script>
{% endblock %}{# html_title #}

{#------------------------------------------------------------------------------------------------#}


{% block content %}

<div class="section">
   <h1>AFCP Admin Console</h1>

{% if info %}
  <div class="info message">
    {{ info|escape }}
    <a href="javascript:void(0);" onclick="closeMessage();">[close]</a>
  </div>
{% endif %}

{% if error %}
  <div class="error message">
    {{ error|escape }}
    <a href="javascript:void(0);" onclick="closeMessage();">[close]</a>
  </div>
{% endif %}

	<h3>Now, the curren activity is :</h3>
       
	 
	
      <table>

        <tr>
          <td class="nowrap" width="1%" align="right">{% trans "Name" %} :</td>
          <td>
            {% if on_inscription_activity.name %}
              {{ on_inscription_activity.name }}
			{% endif %}
          </td>
        </tr>


        <tr>
          <td class="nowrap" width="1%" align="right">{% trans "Subject" %} :</td>
          <td>
            {% if on_inscription_activity.subject %}
              {{ on_inscription_activity.subject }}
            {% else %}
              <i>N/A</i>
            {% endif %}
          </td>
        </tr>


		<tr>
          <td class="nowrap" width="1%" align="right">{% trans "Address" %} :</td>
          <td>
            {% if on_inscription_activity.address %}
              {{ on_inscription_activity.address }}
            {% else %}
              <i>N/A</i>
            {% endif %}
          </td>
        </tr>
		
		<tr>
          <td class="nowrap" width="1%" align="right">{% trans "Date" %} :</td>
          <td>
            {% if on_inscription_activity.date %}
              {{ on_inscription_activity.date|date:"Y-m-d H:M" }}
            {% else %}
              <i>N/A</i>
            {% endif %}
          </td>
        </tr>
	</table>
	<br/>
	
	<h3>You have this operation :</h3>
    <form  id="edit_activity" action="." method="POST" enctype="multipart/form-data">

        Choose l'activity as the current activity:	
		<select name="activity_id">
                <option value="">:: {% trans "Select the current Activity" %} ::</option>
                {% for activity in activities %}
                  {% if activity.isCurrent %}
                    <option value="{{ activity.uid }}" selected="selected">{{ activity.name }}</option>
                  {% else %}
                    <option value="{{ activity.uid }}">{{ activity.name }}</option>
                  {% endif %}
                {% endfor %}
                
        </select>
		
		<input type="button" value="{% trans "Confirm" %}" onclick="submitEditForm();"/>
    </form> 
		  <br/>
        <a href="/afcp/admin/activity/">Return to list</a>
	
</div><!-- section-->


	
{% endblock %}{# content #}

{#------------------------------------------------------------------------------------------------#}







